﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using UIWindows.Attributes;

namespace UIWindows.Models.ParameterModels
{
    public class MESParameterModel : INotifyPropertyChanged
    {
        [Description("其它服务器地址")]
        public string OthenDatabaseurl { get; set; } = @"server=127.0.0.1;port=3306;user=root;password=admin999; database=weightdb;CharSet=utf8mb4;Allow User Variables=True;";
        [Description("MES服务器地址")]
        public string BaseUrl { get; set; } = @"http://47.97.104.170:13308/aiipcapi/";

        #region 员工权限校验
        /// <summary>
        /// 员工权限校验
        /// </summary>
        [Description("员工权限校验")][UIMark("员工权限校验")] public string AccountRoute { get; set; } = "api/ipccheck/account";
        /// <summary>
        /// 员工权限校验超时时间
        /// </summary>
        [Description("员工权限校验超时时间")][UIMark("员工权限校验超时时间")] public int AccountTime { get; set; } = 5000;
        /// <summary>
        /// 员工权限校验重连次数
        /// </summary>
        [Description("员工权限校验重连次数")][UIMark("员工权限校验重连次数")] public int AccountNumber { get; set; } = 3;
        #endregion

        #region 工单获取
        /// <summary>
        ///工单获取
        /// </summary>
        [Description("工单获取")][UIMark("工单获取")] public string GetByProductCodeRoute { get; set; } = "api/station/private/produce/order/getByProductCode";
        /// <summary>
        /// 工单获取超时时间
        /// </summary>
        [Description("工单获取超时时间")][UIMark("工单获取超时时间")] public int GetByProductCodeTime { get; set; } = 5000;
        /// <summary>
        /// 工单获取重连次数
        /// </summary>
        [Description("工单获取重连次数")][UIMark("工单获取重连次数")] public int GetByProductCodeNumber { get; set; } = 3;
        #endregion

        #region 开机上传参数
        /// <summary>
        ///开机上传参数
        /// </summary>
        [Description("开机上传参数")][UIMark("开机上传参数")] public string EquipUploadParamRoute { get; set; } = "api/station/private/produce/equip/uploadParam";
        /// <summary>
        /// 开机上传参数超时时间
        /// </summary>
        [Description("开机上传参数超时时间")][UIMark("开机上传参数超时时间")] public int EquipUploadParamTime { get; set; } = 5000;
        /// <summary>
        /// 开机上传参数重连次数
        /// </summary>
        [Description("开机上传参数重连次数")][UIMark("开机上传参数重连次数")] public int EquipUploadParamNumber { get; set; } = 3;
        #endregion

        #region 修改参数上传
        /// <summary>
        ///修改参数上传
        /// </summary>
        [Description("修改参数上传")][UIMark("修改参数上传")] public string EquipChangeParammRoute { get; set; } = "api/station/private/produce/equip/changeParam";
        /// <summary>
        /// 修改参数上传超时时间
        /// </summary>
        [Description("修改参数上传超时时间")][UIMark("修改参数上传超时时间")] public int EquipChangeParammTime { get; set; } = 5000;
        /// <summary>
        /// 修改参数上传重连次数
        /// </summary>
        [Description("修改参数上传重连次数")][UIMark("修改参数上传重连次数")] public int EquipChangeParammNumber { get; set; } = 3;
        #endregion

        #region 原材料上料
        /// <summary>
        ///原材料上料
        /// </summary>
        [Description("原材料上料")][UIMark("原材料上料")] public string MaterialInRoute { get; set; } = "api/station/private/produce/material/in";
        /// <summary>
        /// 原材料上料超时时间
        /// </summary>
        [Description("原材料上料超时时间")][UIMark("原材料上料超时时间")] public int MaterialInTime { get; set; } = 5000;
        /// <summary>
        /// 原材料上料重连次数
        /// </summary>
        [Description("原材料上料重连次数")][UIMark("原材料上料重连次数")] public int MaterialInNumber { get; set; } = 3;
        #endregion

        #region 原材料卸料
        /// <summary>
        ///原材料卸料
        /// </summary>
        [Description("原材料卸料")][UIMark("原材料卸料")] public string MaterialOutRoute { get; set; } = "api/station/private/produce/material/out";
        /// <summary>
        /// 原材料卸料超时时间
        /// </summary>
        [Description("原材料卸料超时时间")][UIMark("原材料卸料超时时间")] public int MaterialOutTime { get; set; } = 5000;
        /// <summary>
        /// 原材料卸料重连次数
        /// </summary>
        [Description("原材料卸料重连次数")][UIMark("原材料卸料重连次数")] public int MaterialOutNumber { get; set; } = 3;
        #endregion

        #region 工装夹具寿命
        /// <summary>
        /// 工装夹具寿命
        /// </summary>
        [Description("工装夹具寿命")][UIMark("工装夹具寿命")] public string FrockLifeRouter { get; set; } = "api/station/private/produce/frock/life";
        /// <summary>
        /// 工装夹具寿命超时时间
        /// </summary>
        [Description("工装夹具寿命超时时间")][UIMark("工装夹具寿命超时时间")] public int FrockLifeTime { get; set; } = 5000;
        /// <summary>
        /// 工装夹具寿命重连次数
        /// </summary>
        [Description("工装夹具寿命重连次数")][UIMark("工装夹具寿命重连次数")] public int FrockLifeNumber { get; set; } = 3;
        #endregion

        #region 工装夹具更换
        /// <summary>
        /// 工装夹具更换
        /// </summary>
        [Description("工装夹具更换")][UIMark("工装夹具更换")] public string FrockChangeRouter { get; set; } = "api/station/private/produce/frock/change";
        /// <summary>
        /// 工装夹具更换超时时间
        /// </summary>
        [Description("工装夹具更换超时时间")][UIMark("工装夹具更换超时时间")] public int FrockChangeTime { get; set; } = 5000;
        /// <summary>
        /// 工装夹具更换重连次数
        /// </summary>
        [Description("工装夹具更换重连次数")][UIMark("工装夹具更换重连次数")] public int FrockChangeNumber { get; set; } = 3;
        #endregion

        #region OEE数据收集
        /// <summary>
        /// OEE数据收集
        /// </summary>
        [Description("OEE数据收集")][UIMark("OEE数据收集")] public string OeeDataRouter { get; set; } = "api/equip/oeeData";
        /// <summary>
        /// OEE数据收集超时时间
        /// </summary>
        [Description("OEE数据收集超时时间")][UIMark("OEE数据收集超时时间")] public int OeeDataTime { get; set; } = 5000;
        /// <summary>
        /// OEE数据收集重连次数
        /// </summary>
        [Description("OEE数据收集重连次数")][UIMark("OEE数据收集重连次数")] public int OeeDataNumber { get; set; } = 3;
        #endregion

        #region 设备状态上报
        /// <summary>
        /// 设备状态上报
        /// </summary>
        [Description("设备状态上报")][UIMark("设备状态上报")] public string OeeStatusRouter { get; set; } = "api/equip/oeeStatus";
        /// <summary>
        /// 设备状态上报超时时间
        /// </summary>
        [Description("设备状态上报超时时间")][UIMark("设备状态上报超时时间")] public int OeeStatusTime { get; set; } = 5000;
        /// <summary>
        /// 设备状态上报重连次数
        /// </summary>
        [Description("设备状态上报重连次数")][UIMark("设备状态上报重连次数")] public int OeeStatusNumber { get; set; } = 3;
        #endregion

        #region 报警及时间上报
        /// <summary>
        /// 报警及时间上报
        /// </summary>
        [Description("报警及时间上报")][UIMark("报警及时间上报")] public string OeeWarningRouter { get; set; } = "api/equip/oeeWarning";
        /// <summary>
        /// 报警及时间上报超时时间
        /// </summary>
        [Description("报警及时间上报超时时间")][UIMark("报警及时间上报超时时间")] public int OeeWarningTime { get; set; } = 5000;
        /// <summary>
        /// 报警及时间上报重连次数
        /// </summary>
        [Description("报警及时间上报重连次数")][UIMark("报警及时间上报重连次数")] public int OeeWarningNumber { get; set; } = 3;
        #endregion

        #region 设备产能上报
        /// <summary>
        /// 设备产能上报
        /// </summary>
        [Description("设备产能上报")][UIMark("设备产能上报")] public string OeeCapacityRouter { get; set; } = "api/equip/oeeCapacity";
        /// <summary>
        /// 设备产能上报超时时间
        /// </summary>
        [Description("设备产能上报超时时间")][UIMark("设备产能上报超时时间")] public int OeeCapacityTime { get; set; } = 5000;
        /// <summary>
        /// 设备产能上报重连次数
        /// </summary>
        [Description("设备产能上报重连次数")][UIMark("设备产能上报重连次数")] public int OeeCapacityNumber { get; set; } = 3;
        #endregion

        #region 在制品投料
        /// <summary>
        /// 在制品投料防呆校验接口
        /// </summary>
        [Description("在制品投料")][UIMark("在制品投料")] public string PreventionCheckRouter { get; set; } = "api/station/private/produce/feeding/preventionCheck";
        /// <summary>
        /// 在制品投料超时时间
        /// </summary>
        [Description("在制品投料超时时间")][UIMark("在制品投料超时时间")] public int PreventionCheckTime { get; set; } = 5000;
        /// <summary>
        /// 在制品投料重连次数
        /// </summary>
        [Description("在制品投料重连次数")][UIMark("在制品投料重连次数")] public int PreventionCheckNumber { get; set; } = 3;
        #endregion

        #region 结果收集(单条)
        /// <summary>
        /// 结果收集(单条)
        /// </summary>
        [Description("结果收集(单条)")][UIMark("结果收集(单条)")] public string OpenAddRouter { get; set; } = "api/produce/produce/open/add";
        /// <summary>
        /// 结果收集(单条)超时时间
        /// </summary>
        [Description("结果收集(单条)超时时间")][UIMark("结果收集(单条)超时时间")] public int OpenAddTime { get; set; } = 5000;
        /// <summary>
        /// 结果收集(单条)重连次数
        /// </summary>
        [Description("结果收集(单条)重连次数")][UIMark("结果收集(单条)重连次数")] public int OpenAddNumber { get; set; } = 3;
        #endregion

        #region 结果收集(批条)
        /// <summary>
        ///结果收集(批条)
        /// </summary>
        [Description("结果收集(批条)")][UIMark("结果收集(批条)")] public string BatchAddRouter { get; set; } = "api/produce/produce/open/batch/add";
        /// <summary>
        ///结果收集(批条)超时时间
        /// </summary>
        [Description("结果收集(批条)超时时间")][UIMark("结果收集(批条)超时时间")] public int BatchAddTime { get; set; } = 5000;
        /// <summary>
        ///结果收集(批条)重连次数
        /// </summary>
        [Description("结果收集(批条)重连次数")][UIMark("结果收集(批条)重连次数")] public int BatchAddNumber { get; set; } = 3;
        #endregion

        public event PropertyChangedEventHandler? PropertyChanged;
    }
}
